* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Helvetica Neue', Arial, sans-serif;
}

body {
    background-color: #f8f9fa;
    min-height: 100vh;
    color: #333;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}


/* 导航栏样式 */

header {
    background-color: #fff;
    border-bottom: 1px solid #eaeaea;
    padding: 15px 20px;
    position: sticky;
    top: 0;
    z-index: 100;
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 24px;
    font-weight: 700;
    color: #4a6fa5;
}

.nav-links a {
    text-decoration: none;
    color: #555;
    margin-left: 20px;
    font-size: 16px;
}

.nav-links a:hover {
    color: #4a6fa5;
}


/* 首页内容样式 */

.hero {
    text-align: center;
    padding: 60px 20px;
    margin-bottom: 40px;
    background: linear-gradient(135deg, #f5f7fa 0%, #e4e7eb 100%);
    border-radius: 12px;
}

.hero h1 {
    font-size: 36px;
    color: #222;
    margin-bottom: 20px;
    font-weight: 700;
}

.hero p {
    font-size: 18px;
    color: #666;
    max-width: 800px;
    margin: 0 auto 30px;
    line-height: 1.6;
}


/* 类别网格样式 */

.section-title {
    font-size: 24px;
    color: #222;
    margin-bottom: 30px;
    font-weight: 600;
    padding-bottom: 15px;
    border-bottom: 2px solid #4a6fa5;
    display: inline-block;
}

.categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 25px;
    margin-bottom: 50px;
}

.category-card {
    background-color: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    cursor: pointer;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.category-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.category-icon {
    height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 50px;
    color: #fff;
}

.category-card:nth-child(1) .category-icon {
    background-color: #4a6fa5;
}


/* 社会 */

.category-card:nth-child(2) .category-icon {
    background-color: #5b8c85;
}


/* 历史 */

.category-card:nth-child(3) .category-icon {
    background-color: #d1a083;
}


/* 经济 */

.category-card:nth-child(4) .category-icon {
    background-color: #8c6d78;
}


/* 文化 */

.category-card:nth-child(5) .category-icon {
    background-color: #6a9fb5;
}


/* 科技 */

.category-card:nth-child(6) .category-icon {
    background-color: #7ba05b;
}


/* 科学 */

.category-card:nth-child(7) .category-icon {
    background-color: #b2794d;
}


/* 其他 */

.category-content {
    padding: 20px;
    flex-grow: 1;
}

.category-title {
    font-size: 20px;
    color: #222;
    margin-bottom: 10px;
    font-weight: 600;
}

.category-count {
    font-size: 14px;
    color: #666;
    margin-bottom: 15px;
}

.btn {
    display: inline-block;
    background-color: #4a6fa5;
    color: #fff;
    padding: 10px 20px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
}

.btn:hover {
    background-color: #3a5a80;
}


/* 精选文章样式 */

.featured-articles {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 25px;
    margin-bottom: 50px;
}

.article-card {
    background-color: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    cursor: pointer;
}

.article-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.article-thumbnail {
    height: 180px;
    background-color: #e4e7eb;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: #777;
    position: relative;
}

.article-badge {
    position: absolute;
    top: 15px;
    left: 15px;
    background-color: #4a6fa5;
    color: #fff;
    padding: 5px 12px;
    border-radius: 50px;
    font-size: 12px;
    font-weight: 500;
}

.article-content {
    padding: 20px;
}

.article-title {
    font-size: 18px;
    color: #222;
    margin-bottom: 12px;
    font-weight: 600;
    line-height: 1.4;
}

.article-meta {
    display: flex;
    gap: 15px;
    color: #666;
    font-size: 14px;
    margin-bottom: 15px;
}

.article-excerpt {
    font-size: 15px;
    color: #666;
    line-height: 1.6;
    margin-bottom: 20px;
}


/* 页脚样式 */

footer {
    background-color: #fff;
    padding: 30px 20px;
    border-top: 1px solid #eaeaea;
    margin-top: 50px;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.footer-links a {
    text-decoration: none;
    color: #666;
    margin-left: 20px;
    font-size: 14px;
}

.footer-links a:hover {
    color: #4a6fa5;
}

.copyright {
    color: #888;
    font-size: 14px;
}


/* 响应式设计 */

@media (max-width: 768px) {
    .hero h1 {
        font-size: 28px;
    }
    .hero p {
        font-size: 16px;
    }
    .categories-grid {
        grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    }
    .featured-articles {
        grid-template-columns: 1fr;
    }
    .navbar {
        flex-direction: column;
        gap: 15px;
    }
    .nav-links {
        display: flex;
        justify-content: center;
        flex-wrap: wrap;
        gap: 10px;
        margin-top: 15px;
    }
    .nav-links a {
        margin: 0;
        padding: 5px 10px;
    }
    .footer-content {
        flex-direction: column;
        gap: 20px;
        text-align: center;
    }
    .footer-links {
        display: flex;
        justify-content: center;
        flex-wrap: wrap;
        gap: 10px;
    }
}